<HTML><HEAD><TITLE>alarm(+Clock)</TITLE>
</HEAD><BODY>[ <A HREF="index.html">Operating System</A> | <A HREF="../../index.html">Reference Manual</A> | <A HREF="../../fullindex.html">Alphabetic Index</A> ]
<H1>alarm(+Clock)</H1>
The operating system will send the signal 14 to the ECLiPSe system Clock
seconds after the command was entered.


<DL>
<DT><EM>Clock</EM></DT>
<DD>Integer
</DD>
</DL>
<H2>Description</H2>
   Used to send the signal 14 (SIGALRM) to the ECLiPSe system Clock seconds
   after the alarm/1 command is entered.  If there is already a pending
   alarm, its clock is merely reset, i.e.  there cannot be multiple alarm
   requests.

<P>
   If Clock is 0, any pending alarm is cancelled.  If Clock is negative, it
   is nevertheless interpreted as an unsigned integer.

<P>

<H3>Modes and Determinism</H3><UL>
<LI>alarm(+) is det
</UL>
<H3>Exceptions</H3>
<DL>
<DT><EM>(4) instantiation fault </EM>
<DD>Clock is not instantiated.
<DT><EM>(5) type error </EM>
<DD>Clock is not an integer.
</DL>
<H2>Examples</H2>
<PRE>
Success:
      [eclipse]: alarm(1).
      yes.
      [eclipse]: Signal 14         % 1 second later

Error:
      alarm(I).                    (Error 4).
      alarm(2.0).                  (Error 5).



</PRE>
<H2>See Also</H2>
<A HREF="../../kernel/opsys/sleep-1.html">sleep / 1</A>
</BODY></HTML>
